import request from '@/utils/request'

// 查询分组属性关联列表
export function listAttrattrgroup(query) {
  return request({
    url: '/product/attr/attrgroup/list',
    method: 'get',
    params: query
  })
}

// 查询分组属性关联详细
export function getAttrattrgroup(attrId) {
  return request({
    url: '/product/attr/attrgroup/' + attrId,
    method: 'get'
  })
}

// 新增分组属性关联
export function addAttrattrgroup(data) {
  return request({
    url: '/product/attr/attrgroup',
    method: 'post',
    data: data
  })
}

export function addAttrattrgroupList(data) {
  return request({
    url: '/product/attr/attrgroup/list',
    method: 'post',
    data: data
  })
}

// 修改分组属性关联
export function updateAttrattrgroup(data) {
  return request({
    url: '/product/attr/attrgroup',
    method: 'put',
    data: data
  })
}

// 删除分组属性关联
export function delAttrattrgroup(data) {
  return request({
    url: '/product/attr/attrgroup/',
    method: 'delete',
    data:data
  })
}
